home *** CD-ROM | disk | FTP | other *** search
/ Developer CD Series 1997 July: Mac OS SDK / Dev.CD Jul 97 SDK1.toast / Development Kits (Disc 1) / Interfaces&Libraries / Interfaces / CIncludes / Gestalt.h < prev    next >
Encoding:
C/C++ Source or Header  |  1996-05-03  |  33.9 KB  |  1,021 lines  |  [TEXT/MPS ]

  1. /*
  2.      File:        Gestalt.h
  3.  
  4.      Contains:    Gestalt Interfaces.
  5.  
  6.      Version:    Technology:    System 7.5
  7.                  Package:    Universal Interfaces 2.1.3
  8.  
  9.      Copyright:    © 1984-1996 by Apple Computer, Inc.
  10.                  All rights reserved.
  11.  
  12.      Bugs?:        If you find a problem with this file, use the Apple Bug Reporter
  13.                  stack.  Include the file and version information (from above)
  14.                  in the problem description and send to:
  15.                      Internet:    apple.bugs@applelink.apple.com
  16.                      AppleLink:    APPLE.BUGS
  17.  
  18. */
  19.  
  20. #ifndef __GESTALT__
  21. #define __GESTALT__
  22.  
  23.  
  24. #ifndef __TYPES__
  25. #include <Types.h>
  26. #endif
  27. /*    #include <ConditionalMacros.h>                                */
  28.  
  29. #ifndef __MIXEDMODE__
  30. #include <MixedMode.h>
  31. #endif
  32.  
  33. #ifdef __cplusplus
  34. extern "C" {
  35. #endif
  36.  
  37. #if PRAGMA_ALIGN_SUPPORTED
  38. #pragma options align=mac68k
  39. #endif
  40.  
  41. #if PRAGMA_IMPORT_SUPPORTED
  42. #pragma import on
  43. #endif
  44.  
  45.  
  46. enum {
  47.     gestaltAddressingModeAttr    = 'addr',                        /* addressing mode attributes */
  48.     gestalt32BitAddressing        = 0,                            /* using 32-bit addressing mode */
  49.     gestalt32BitSysZone            = 1,                            /* 32-bit compatible system zone */
  50.     gestalt32BitCapable            = 2                                /* Machine is 32-bit capable */
  51. };
  52.  
  53. enum {
  54.     gestaltAliasMgrAttr            = 'alis',                        /* Alias Mgr Attributes */
  55.     gestaltAliasMgrPresent        = 0,                            /* True if the Alias Mgr is present */
  56.     gestaltAliasMgrSupportsRemoteAppletalk = 1                    /* True if the Alias Mgr knows about Remote Appletalk */
  57. };
  58.  
  59. enum {
  60.     gestaltAppleTalkVersion        = 'atlk'
  61. };
  62.  
  63. enum {
  64.     gestaltAUXVersion            = 'a/ux'
  65. };
  66.  
  67. enum {
  68.     gestaltCloseViewAttr        = 'BSDa',                        /* CloseView attributes */
  69.     gestaltCloseViewEnabled        = 0,                            /* Closeview enabled (dynamic bit - returns current state) */
  70.     gestaltCloseViewDisplayMgrFriendly = 1                        /* Closeview compatible with Display Manager (FUTURE) */
  71. };
  72.  
  73. enum {
  74.     gestaltCFMAttr                = 'cfrg',                        /* returns information about the Code Fragment Manager */
  75.     gestaltCFMPresent            = 0                                /* true if the Code Fragment Manager is present */
  76. };
  77.  
  78. enum {
  79.     gestaltColorMatchingAttr    = 'cmta',                        /* ColorSync attributes */
  80.     gestaltHighLevelMatching    = 0,
  81.     gestaltColorMatchingLibLoaded = 1
  82. };
  83.  
  84. enum {
  85.     gestaltColorMatchingVersion    = 'cmtc',
  86.     gestaltColorSync10            = 0x0100,                        /* 0x0100 & 0x0110 _Gestalt versions for 1.0-1.0.3 product */
  87.     gestaltColorSync11            = 0x0110,                        /*   0x0100 == low-level matching only */
  88.     gestaltColorSync104            = 0x0104,                        /* Real version, by popular demand */
  89.     gestaltColorSync105            = 0x0105
  90. };
  91.  
  92. enum {
  93.     gestaltConnMgrAttr            = 'conn',                        /* connection mgr attributes    */
  94.     gestaltConnMgrPresent        = 0,
  95.     gestaltConnMgrCMSearchFix    = 1,                            /* Fix to CMAddSearch?     */
  96.     gestaltConnMgrErrorString    = 2,                            /* has CMGetErrorString() */
  97.     gestaltConnMgrMultiAsyncIO    = 3                                /* CMNewIOPB, CMDisposeIOPB, CMPBRead, CMPBWrite, CMPBIOKill */
  98. };
  99.  
  100. enum {
  101.     gestaltComponentMgr            = 'cpnt'
  102. };
  103.  
  104. enum {
  105.     gestaltColorPickerVersion    = 'cpkr',                        /* returns version of ColorPicker */
  106.     gestaltColorPicker            = 'cpkr'
  107. };
  108.  
  109. /*
  110.     The gestaltNativeCPUtype ('cput') selector can be used to determine the
  111.     native CPU type for all Macs running System 7.5 or later.
  112.     
  113.     The 'cput' selector is not available when running System 7.0 (or earlier)
  114.     on most 68K machines.  If 'cput' is not available, then the 'proc' selector
  115.     should be used to determine the processor type.
  116.     
  117.     An application should always try the 'cput' selector first.  This is because,
  118.     on PowerPC machines, the 'proc' selector will reflect the CPU type of the
  119.     emulator's "virtual processor" rather than the native CPU type.
  120.     
  121.     The values specified below are accurate.  Prior versions of the Gestalt
  122.     interface file contained values that were off by one.
  123.     
  124.     The Quadra 840AV and the Quadra 660AV contain a bug in the ROM code that
  125.     causes the 'cput' selector to respond with the value 5.  This behavior
  126.     occurs only when running System 7.1.  System 7.5 fixes the bug by replacing
  127.     the faulty 'cput' selector function with the correct one.
  128. */
  129.  
  130. enum {
  131.     gestaltNativeCPUtype        = 'cput',                        /* Native CPU type                                       */
  132.     gestaltCPU68000                = 0,                            /* Various 68k CPUs...     */
  133.     gestaltCPU68010                = 1,
  134.     gestaltCPU68020                = 2,
  135.     gestaltCPU68030                = 3,
  136.     gestaltCPU68040                = 4,
  137.     gestaltCPU601                = 0x0101,                        /* IBM 601                                                 */
  138.     gestaltCPU603                = 0x0103,
  139.     gestaltCPU604                = 0x0104,
  140.     gestaltCPU603e                = 0x0106
  141. };
  142.  
  143. enum {
  144.     gestaltCRMAttr                = 'crm ',                        /* comm resource mgr attributes */
  145.     gestaltCRMPresent            = 0,
  146.     gestaltCRMPersistentFix        = 1,                            /* fix for persistent tools */
  147.     gestaltCRMToolRsrcCalls        = 2                                /* has CRMGetToolResource/ReleaseToolResource */
  148. };
  149.  
  150. enum {
  151.     gestaltControlStripVersion    = 'csvr'
  152. };
  153.  
  154. enum {
  155.     gestaltCTBVersion            = 'ctbv'
  156. };
  157.  
  158. enum {
  159.     gestaltDBAccessMgrAttr        = 'dbac',                        /* Database Access Mgr attributes */
  160.     gestaltDBAccessMgrPresent    = 0                                /* True if Database Access Mgr present */
  161. };
  162.  
  163. enum {
  164.     gestaltDictionaryMgrAttr    = 'dict',                        /* Dictionary Manager attributes */
  165.     gestaltDictionaryMgrPresent    = 0                                /* Dictionary Manager attributes */
  166. };
  167.  
  168. enum {
  169.     gestaltDITLExtAttr            = 'ditl',                        /* AppenDITL, etc. calls from CTB */
  170.     gestaltDITLExtPresent        = 0                                /* True if calls are present */
  171. };
  172.  
  173. enum {
  174.     gestaltDisplayMgrAttr        = 'dply',                        /* Display Manager attributes */
  175.     gestaltDisplayMgrPresent    = 0,                            /* True if Display Mgr is present */
  176.     gestaltDisplayMgrCanSwitchMirrored = 2,                        /* True if Display Mgr can switch modes on mirrored displays */
  177.     gestaltDisplayMgrSetDepthNotifies = 3                        /* True SetDepth generates displays mgr notification */
  178. };
  179.  
  180. enum {
  181.     gestaltDisplayMgrVers        = 'dplv'
  182. };
  183.  
  184. enum {
  185.     gestaltDragMgrAttr            = 'drag',                        /* Drag Manager attributes */
  186.     gestaltDragMgrPresent        = 0,                            /* Drag Manager is present */
  187.     gestaltDragMgrFloatingWind    = 1,                            /* Drag Manager supports floating windows */
  188.     gestaltPPCDragLibPresent    = 2                                /* Drag Manager PPC DragLib is present */
  189. };
  190.  
  191. enum {
  192.     gestaltEasyAccessAttr        = 'easy',                        /* Easy Access attributes */
  193.     gestaltEasyAccessOff        = 0,                            /* if Easy Access present, but off (no icon) */
  194.     gestaltEasyAccessOn            = 1,                            /* if Easy Access "On" */
  195.     gestaltEasyAccessSticky        = 2,                            /* if Easy Access "Sticky" */
  196.     gestaltEasyAccessLocked        = 3                                /* if Easy Access "Locked" */
  197. };
  198.  
  199. enum {
  200.     gestaltEditionMgrAttr        = 'edtn',                        /* Edition Mgr attributes */
  201.     gestaltEditionMgrPresent    = 0,                            /* True if Edition Mgr present */
  202.     gestaltEditionMgrTranslationAware = 1                        /* True if edition manager is translation manager aware */
  203. };
  204.  
  205. enum {
  206.     gestaltAppleEventsAttr        = 'evnt',                        /* Apple Events attributes */
  207.     gestaltAppleEventsPresent    = 0,                            /* True if Apple Events present */
  208.     gestaltScriptingSupport        = 1,
  209.     gestaltOSLInSystem            = 2                                /* OSL is in system so don’t use the one linked in to app */
  210. };
  211.  
  212. enum {
  213.     gestaltFinderAttr            = 'fndr',                        /* Finder attributes */
  214.     gestaltFinderDropEvent        = 0,                            /* Finder recognizes drop event */
  215.     gestaltFinderMagicPlacement    = 1,                            /* Finder supports magic icon placement */
  216.     gestaltFinderCallsAEProcess    = 2,                            /* Finder calls AEProcessAppleEvent */
  217.     gestaltOSLCompliantFinder    = 3,                            /* Finder is scriptable and recordable */
  218.     gestaltFinderSupports4GBVolumes = 4,                        /* Finder correctly handles 4GB volumes */
  219.     gestaltFinderHasClippings    = 6                                /* Finder supports Drag Manager clipping files */
  220. };
  221.  
  222. enum {
  223.     gestaltFindFolderAttr        = 'fold',                        /* Folder Mgr attributes */
  224.     gestaltFindFolderPresent    = 0                                /* True if Folder Mgr present */
  225. };
  226.  
  227. enum {
  228.     gestaltFontMgrAttr            = 'font',                        /* Font Mgr attributes */
  229.     gestaltOutlineFonts            = 0                                /* True if Outline Fonts supported */
  230. };
  231.  
  232. enum {
  233.     gestaltFPUType                = 'fpu ',                        /* fpu type */
  234.     gestaltNoFPU                = 0,                            /* no FPU */
  235.     gestalt68881                = 1,                            /* 68881 FPU */
  236.     gestalt68882                = 2,                            /* 68882 FPU */
  237.     gestalt68040FPU                = 3                                /* 68040 built-in FPU */
  238. };
  239.  
  240. enum {
  241.     gestaltFSAttr                = 'fs  ',                        /* file system attributes */
  242.     gestaltFullExtFSDispatching    = 0,                            /* has really cool new HFSDispatch dispatcher */
  243.     gestaltHasFSSpecCalls        = 1,                            /* has FSSpec calls */
  244.     gestaltHasFileSystemManager    = 2,                            /* has a file system manager */
  245.     gestaltFSMDoesDynamicLoad    = 3,                            /* file system manager supports dynamic loading */
  246.     gestaltFSSupports4GBVols    = 4,                            /* file system supports 4 gigabyte volumes */
  247.     gestaltFSSupports2TBVols    = 5,                            /* file system supports 2 terabyte volumes */
  248.     gestaltHasExtendedDiskInit    = 6                                /* has extended Disk Initialization calls */
  249. };
  250.  
  251. #if !OLDROUTINELOCATIONS
  252. enum {
  253.     gestaltFSMVersion            = 'fsm '
  254. };
  255.  
  256. #endif
  257. enum {
  258.     gestaltFXfrMgrAttr            = 'fxfr',                        /* file transfer manager attributes */
  259.     gestaltFXfrMgrPresent        = 0,
  260.     gestaltFXfrMgrMultiFile        = 1,                            /* supports FTSend and FTReceive */
  261.     gestaltFXfrMgrErrorString    = 2                                /* supports FTGetErrorString */
  262. };
  263.  
  264. enum {
  265.     gestaltGraphicsAttr            = 'gfxa',                        /* Quickdraw GX attributes selector */
  266.     gestaltGraphicsIsDebugging    = 0x00000001,
  267.     gestaltGraphicsIsLoaded        = 0x00000002,
  268.     gestaltGraphicsIsPowerPC    = 0x00000004
  269. };
  270.  
  271. enum {
  272.     gestaltGraphicsVersion        = 'grfx',                        /* Quickdraw GX version selector */
  273.     gestaltCurrentGraphicsVersion = 0x00010000                    /* the version described in this set of headers */
  274. };
  275.  
  276. enum {
  277.     gestaltHardwareAttr            = 'hdwr',                        /* hardware attributes */
  278.     gestaltHasVIA1                = 0,                            /* VIA1 exists */
  279.     gestaltHasVIA2                = 1,                            /* VIA2 exists */
  280.     gestaltHasASC                = 3,                            /* Apple Sound Chip exists */
  281.     gestaltHasSCC                = 4,                            /* SCC exists */
  282.     gestaltHasSCSI                = 7,                            /* SCSI exists */
  283.     gestaltHasSoftPowerOff        = 19,                            /* Capable of software power off */
  284.     gestaltHasSCSI961            = 21,                            /* 53C96 SCSI controller on internal bus */
  285.     gestaltHasSCSI962            = 22,                            /* 53C96 SCSI controller on external bus */
  286.     gestaltHasUniversalROM        = 24,                            /* Do we have a Universal ROM? */
  287.     gestaltHasEnhancedLtalk        = 30                            /* Do we have Enhanced LocalTalk? */
  288. };
  289.  
  290. enum {
  291.     gestaltHelpMgrAttr            = 'help',                        /* Help Mgr Attributes */
  292.     gestaltHelpMgrPresent        = 0,                            /* true if help mgr is present */
  293.     gestaltHelpMgrExtensions    = 1                                /* true if help mgr extensions are installed */
  294. };
  295.  
  296. enum {
  297.     gestaltCompressionMgr        = 'icmp'
  298. };
  299.  
  300. enum {
  301.     gestaltIconUtilitiesAttr    = 'icon',                        /* Icon Utilities attributes  (Note: available in System 7.0, despite gestalt) */
  302.     gestaltIconUtilitiesPresent    = 0                                /* true if icon utilities are present */
  303. };
  304.  
  305. enum {
  306.     gestaltKeyboardType            = 'kbd ',                        /* keyboard type */
  307.     gestaltMacKbd                = 1,
  308.     gestaltMacAndPad            = 2,
  309.     gestaltMacPlusKbd            = 3,
  310.     gestaltExtADBKbd            = 4,
  311.     gestaltStdADBKbd            = 5,
  312.     gestaltPrtblADBKbd            = 6,
  313.     gestaltPrtblISOKbd            = 7,
  314.     gestaltStdISOADBKbd            = 8,
  315.     gestaltExtISOADBKbd            = 9,
  316.     gestaltADBKbdII                = 10,
  317.     gestaltADBISOKbdII            = 11,
  318.     gestaltPwrBookADBKbd        = 12,
  319.     gestaltPwrBookISOADBKbd        = 13,
  320.     gestaltAppleAdjustKeypad    = 14,
  321.     gestaltAppleAdjustADBKbd    = 15,
  322.     gestaltAppleAdjustISOKbd    = 16,
  323.     gestaltJapanAdjustADBKbd    = 17,                            /* Japan Adjustable Keyboard */
  324.     gestaltPwrBkExtISOKbd        = 20,                            /* PowerBook Extended International Keyboard with function keys */
  325.     gestaltPwrBkExtJISKbd        = 21,                            /* PowerBook Extended Japanese Keyboard with function keys         */
  326.     gestaltPwrBkExtADBKbd        = 24                            /* PowerBook Extended Domestic Keyboard with function keys         */
  327. };
  328.  
  329. enum {
  330.     gestaltLowMemorySize        = 'lmem'
  331. };
  332.  
  333. enum {
  334.     gestaltLogicalRAMSize        = 'lram'
  335. };
  336.  
  337. /*
  338.     MACHINE TYPE CONSTANTS NAMING CONVENTION
  339.     
  340.         All future machine type constant names take the following form:
  341.     
  342.             gestalt<lineName><modelNumber>
  343.             
  344.     Line Names
  345.     
  346.         The following table contains the lines currently produced by Apple and the 
  347.         lineName substrings associated with them:
  348.     
  349.             Line                        lineName
  350.             -------------------------    ------------
  351.             Macintosh LC                "MacLC"
  352.             Macintosh Performa            "Performa"
  353.             Macintosh PowerBook            "PowerBook"
  354.             Macintosh PowerBook Duo        "PowerBookDuo"
  355.             Power Macintosh                "PowerMac"
  356.             Apple Workgroup Server        "AWS"
  357.         
  358.         The following table contains lineNames for some discontinued lines:
  359.     
  360.             Line                        lineName
  361.             -------------------------    ------------
  362.             Macintosh Quadra            "MacQuadra" (preferred)
  363.                                         "Quadra" (also used, but not preferred)
  364.             Macintosh Centris            "MacCentris"
  365.     
  366.     Model Numbers
  367.     
  368.         The modelNumber is a string representing the specific model of the machine
  369.         within its particular line.  For example, for the Power Macintosh 8100/80,
  370.         the modelNumber is "8100".
  371.         
  372.         Some Performa & LC model numbers contain variations in the rightmost 1 or 2
  373.         digits to indicate different RAM and Hard Disk configurations.  A single
  374.         machine type is assigned for all variations of a specific model number.  In
  375.         this case, the modelNumber string consists of the constant leftmost part
  376.         of the model number with 0s for the variant digits.  For example, the
  377.         Performa 6115 and Performa 6116 are both return the same machine type
  378.         constant:  gestaltPerforma6100.    
  379.         
  380.         
  381.     OLD NAMING CONVENTIONS
  382.         
  383.     The "Underscore Speed" suffix
  384.         
  385.         In the past, Apple differentiated between machines that had the same model
  386.         number but different speeds.  For example, the Power Macintosh 8100/80 and
  387.         Power Macintosh 8100/100 return different machine type constants.  This is
  388.         why some existing machine type constant names take the form:
  389.     
  390.             gestalt<lineName><modelNumber>_<speed>
  391.     
  392.         e.g.
  393.     
  394.             gestaltPowerMac8100_110
  395.             gestaltPowerMac7100_80
  396.             gestaltPowerMac7100_66
  397.     
  398.         It is no longer necessary to use the "underscore speed" suffix.  Starting with
  399.         the Power Surge machines (Power Macintosh 7200, 7500, 8500 and 9500), speed is
  400.         no longer used to differentiate between machine types.  This is why a Power
  401.         Macintosh 7200/75 and a Power Macintosh 7200/90 return the same machine type
  402.         constant:  gestaltPowerMac7200.
  403.         
  404.     The "Screen Type" suffix
  405.         
  406.         All PowerBook models prior to the PowerBook 190, and all PowerBook Duo models
  407.         before the PowerBook Duo 2300 take the form:
  408.         
  409.             gestalt<lineName><modelNumber><screenType>
  410.         
  411.         Where <screenType> is "c" or the empty string.
  412.         
  413.         e.g.
  414.         
  415.             gestaltPowerBook100
  416.             gestaltPowerBookDuo280
  417.             gestaltPowerBookDuo280c
  418.             gestaltPowerBook180
  419.             gestaltPowerBook180c
  420.         
  421.         Starting with the PowerBook 190 series and the PowerBook Duo 2300 series, machine
  422.         types are no longer differentiated based on screen type.  This is why a PowerBook
  423.         5300cs/100 and a PowerBook 5300c/100 both return the same machine type constant:
  424.         gestaltPowerBook5300.
  425.     
  426.         Macintosh LC 630                gestaltMacLC630
  427.         Macintosh Performa 6200            gestaltPerforma6200
  428.         Macintosh Quadra 700            gestaltQuadra700
  429.         Macintosh PowerBook 5300        gestaltPowerBook5300
  430.         Macintosh PowerBook Duo 2300    gestaltPowerBookDuo2300
  431.         Power Macintosh 8500            gestaltPowerMac8500
  432. */
  433.  
  434. enum {
  435.     gestaltMachineType            = 'mach',                        /* machine type */
  436.     gestaltClassic                = 1,
  437.     gestaltMacXL                = 2,
  438.     gestaltMac512KE                = 3,
  439.     gestaltMacPlus                = 4,
  440.     gestaltMacSE                = 5,
  441.     gestaltMacII                = 6,
  442.     gestaltMacIIx                = 7,
  443.     gestaltMacIIcx                = 8,
  444.     gestaltMacSE030                = 9,
  445.     gestaltPortable                = 10,
  446.     gestaltMacIIci                = 11,
  447.     gestaltMacIIfx                = 13,
  448.     gestaltMacClassic            = 17,
  449.     gestaltMacIIsi                = 18,
  450.     gestaltMacLC                = 19,
  451.     gestaltQuadra900            = 20,
  452.     gestaltPowerBook170            = 21,
  453.     gestaltQuadra700            = 22,
  454.     gestaltClassicII            = 23,
  455.     gestaltPowerBook100            = 24,
  456.     gestaltPowerBook140            = 25,
  457.     gestaltQuadra950            = 26,
  458.     gestaltMacLCIII                = 27,
  459.     gestaltPerforma450            = gestaltMacLCIII,
  460.     gestaltPowerBookDuo210        = 29,
  461.     gestaltMacCentris650        = 30,
  462.     gestaltPowerBookDuo230        = 32,
  463.     gestaltPowerBook180            = 33,
  464.     gestaltPowerBook160            = 34,
  465.     gestaltMacQuadra800            = 35,
  466.     gestaltMacQuadra650            = 36,
  467.     gestaltMacLCII                = 37,
  468.     gestaltPowerBookDuo250        = 38,
  469.     gestaltAWS9150_80            = 39,
  470.     gestaltPowerMac8100_110        = 40,
  471.     gestaltAWS8150_110            = gestaltPowerMac8100_110,
  472.     gestaltPowerMac5200            = 41,
  473.     gestaltPowerMac6200            = 42,
  474.     gestaltMacIIvi                = 44,
  475.     gestaltMacIIvm                = 45,
  476.     gestaltPerforma600            = gestaltMacIIvm,
  477.     gestaltPowerMac7100_80        = 47,
  478.     gestaltMacIIvx                = 48,
  479.     gestaltMacColorClassic        = 49,
  480.     gestaltPerforma250            = gestaltMacColorClassic,
  481.     gestaltPowerBook165c        = 50,
  482.     gestaltMacCentris610        = 52,
  483.     gestaltMacQuadra610            = 53,
  484.     gestaltPowerBook145            = 54,
  485.     gestaltPowerMac8100_100        = 55,
  486.     gestaltMacLC520                = 56,
  487.     gestaltAWS9150_120            = 57,
  488.     gestaltMacCentris660AV        = 60,
  489.     gestaltPerforma46x            = 62,
  490.     gestaltPowerMac8100_80        = 65,
  491.     gestaltAWS8150_80            = gestaltPowerMac8100_80,
  492.     gestaltPowerMac9500            = 67,
  493.     gestaltPowerMac7500            = 68,
  494.     gestaltPowerMac8500            = 69,
  495.     gestaltPowerBook180c        = 71,
  496.     gestaltPowerBook520            = 72,
  497.     gestaltPowerBook520c        = gestaltPowerBook520,
  498.     gestaltPowerBook540            = gestaltPowerBook520,
  499.     gestaltPowerBook540c        = gestaltPowerBook520,
  500.     gestaltPowerMac6100_60        = 75,
  501.     gestaltAWS6150_60            = gestaltPowerMac6100_60,
  502.     gestaltPowerBookDuo270c        = 77,
  503.     gestaltMacQuadra840AV        = 78,
  504.     gestaltPerforma550            = 80,
  505.     gestaltPowerBook165            = 84,
  506.     gestaltPowerBook190            = 85,
  507.     gestaltMacTV                = 88,
  508.     gestaltMacLC475                = 89,
  509.     gestaltPerforma47x            = gestaltMacLC475,
  510.     gestaltMacLC575                = 92,
  511.     gestaltMacQuadra605            = 94,
  512.     gestaltQuadra630            = 98,
  513.     gestaltPowerMac6100_66        = 100,
  514.     gestaltAWS6150_66            = gestaltPowerMac6100_66,
  515.     gestaltPowerBookDuo280        = 102,
  516.     gestaltPowerBookDuo280c        = 103,
  517.     gestaltPowerMac7200            = 108,
  518.     gestaltPowerMac7100_66        = 112,                            /* Power Macintosh 7100/66 */
  519.     gestaltPowerBook150            = 115,
  520.     gestaltPowerBookDuo2300        = 124,
  521.     gestaltPowerBook500PPCUpgrade = 126,
  522.     gestaltPowerBook5300        = 128
  523. };
  524.  
  525.  
  526. enum {
  527.     kMachineNameStrID            = -16395
  528. };
  529.  
  530. enum {
  531.     gestaltMachineIcon            = 'micn'
  532. };
  533.  
  534. enum {
  535.     gestaltMiscAttr                = 'misc',                        /* miscellaneous attributes */
  536.     gestaltScrollingThrottle    = 0,                            /* true if scrolling throttle on */
  537.     gestaltSquareMenuBar        = 2                                /* true if menu bar is square */
  538. };
  539.  
  540. /*
  541.     The name gestaltMixedModeVersion for the 'mixd' selector is semantically incorrect.
  542.     The same selector has been renamed gestaltMixedModeAttr to properly reflect the
  543.     Inside Mac: PowerPC System Software documentation.  The gestaltMixedModeVersion
  544.     symbol has been preserved only for backwards compatibility.
  545.  
  546.     Developers are forewarned that gestaltMixedModeVersion has a limited lifespan and
  547.     will be removed in a future release of the Interfaces.
  548.  
  549.     For the first version of Mixed Mode, both meanings of the 'mixd' selector are
  550.     functionally identical.  They both return 0x00000001.  In subsequent versions
  551.     of Mixed Mode, however, the 'mixd' selector will not respond with an increasing
  552.     version number, but rather, with 32 attribute bits with various meanings.
  553. */
  554. enum {
  555.     gestaltMixedModeVersion        = 'mixd'
  556. };
  557.  
  558. enum {
  559.     gestaltMixedModeAttr        = 'mixd',                        /* returns Mixed Mode attributes */
  560.     gestaltMixedModePowerPC        = 0,                            /* true if Mixed Mode supports PowerPC ABI calling conventions */
  561.     gestaltPowerPCAware            = 0,                            /* old name for gestaltMixedModePowerPC */
  562.     gestaltMixedModeCFM68K        = 1,                            /* true if Mixed Mode supports CFM-68K calling conventions */
  563.     gestaltMixedModeCFM68KHasTrap = 2                            /* true if CFM-68K Mixed Mode implements _MixedModeDispatch (versions 1.0.1 and prior did not) */
  564. };
  565.  
  566. enum {
  567.     gestaltMMUType                = 'mmu ',                        /* mmu type */
  568.     gestaltNoMMU                = 0,                            /* no MMU */
  569.     gestaltAMU                    = 1,                            /* address management unit */
  570.     gestalt68851                = 2,                            /* 68851 PMMU */
  571.     gestalt68030MMU                = 3,                            /* 68030 built-in MMU */
  572.     gestalt68040MMU                = 4,                            /* 68040 built-in MMU */
  573.     gestaltEMMU1                = 5                                /* Emulated MMU type 1  */
  574. };
  575.  
  576. enum {
  577.     gestaltStdNBPAttr            = 'nlup',                        /* standard nbp attributes */
  578.     gestaltStdNBPPresent        = 0
  579. };
  580.  
  581. enum {
  582.     gestaltNotificationMgrAttr    = 'nmgr',                        /* notification manager attributes */
  583.     gestaltNotificationPresent    = 0                                /* notification manager exists */
  584. };
  585.  
  586. enum {
  587.     gestaltNameRegistryVersion    = 'nreg'
  588. };
  589.  
  590. enum {
  591.     gestaltNuBusSlotCount        = 'nubs'
  592. };
  593.  
  594. enum {
  595.     gestaltOpenFirmwareInfo        = 'opfw'
  596. };
  597.  
  598. enum {
  599.     gestaltOSAttr                = 'os  ',                        /* o/s attributes */
  600.     gestaltSysZoneGrowable        = 0,                            /* system heap is growable */
  601.     gestaltLaunchCanReturn        = 1,                            /* can return from launch */
  602.     gestaltLaunchFullFileSpec    = 2,                            /* can launch from full file spec */
  603.     gestaltLaunchControl        = 3,                            /* launch control support available */
  604.     gestaltTempMemSupport        = 4,                            /* temp memory support */
  605.     gestaltRealTempMemory        = 5,                            /* temp memory handles are real */
  606.     gestaltTempMemTracked        = 6,                            /* temporary memory handles are tracked */
  607.     gestaltIPCSupport            = 7,                            /* IPC support is present */
  608.     gestaltSysDebuggerSupport    = 8                                /* system debugger support is present */
  609. };
  610.  
  611. enum {
  612.     gestaltOSTable                = 'ostt'
  613. };
  614.  
  615. enum {
  616.     gestaltPCXAttr                = 'pcxg',                        /* PC Exchange attributes */
  617.     gestaltPCXHas8and16BitFAT    = 0,                            /* PC Exchange supports both 8 and 16 bit FATs */
  618.     gestaltPCXHasProDOS            = 1                                /* PC Exchange supports ProDOS */
  619. };
  620.  
  621. enum {
  622.     gestaltLogicalPageSize        = 'pgsz'
  623. };
  624.  
  625. enum {
  626.     gestaltPopupAttr            = 'pop!',                        /* popup cdef attributes */
  627.     gestaltPopupPresent            = 0
  628. };
  629.  
  630. enum {
  631.     gestaltPowerMgrAttr            = 'powr',                        /* power manager attributes */
  632.     gestaltPMgrExists            = 0,
  633.     gestaltPMgrCPUIdle            = 1,
  634.     gestaltPMgrSCC                = 2,
  635.     gestaltPMgrSound            = 3,
  636.     gestaltPMgrDispatchExists    = 4
  637. };
  638.  
  639. /*
  640.  * PPC will return the combination of following bit fields.
  641.  * e.g. gestaltPPCSupportsRealTime +gestaltPPCSupportsIncoming + gestaltPPCSupportsOutGoing
  642.  * indicates PPC is cuurently is only supports real time delivery
  643.  * and both incoming and outgoing network sessions are allowed.
  644.  * By default local real time delivery is supported as long as PPCInit has been called.*/
  645. enum {
  646.     gestaltPPCToolboxAttr        = 'ppc ',                        /* PPC toolbox attributes */
  647.     gestaltPPCToolboxPresent    = 0x0000,                        /* PPC Toolbox is present  Requires PPCInit to be called */
  648.     gestaltPPCSupportsRealTime    = 0x1000,                        /* PPC Supports real-time delivery */
  649.     gestaltPPCSupportsIncoming    = 0x0001,                        /* PPC will deny incoming network requests */
  650.     gestaltPPCSupportsOutGoing    = 0x0002                        /* PPC will deny outgoing network requests */
  651. };
  652.  
  653. enum {
  654.     gestaltProcessorType        = 'proc',                        /* processor type */
  655.     gestalt68000                = 1,
  656.     gestalt68010                = 2,
  657.     gestalt68020                = 3,
  658.     gestalt68030                = 4,
  659.     gestalt68040                = 5
  660. };
  661.  
  662. enum {
  663.     gestaltParityAttr            = 'prty',                        /* parity attributes */
  664.     gestaltHasParityCapability    = 0,                            /* has ability to check parity */
  665.     gestaltParityEnabled        = 1                                /* parity checking enabled */
  666. };
  667.  
  668. enum {
  669.     gestaltQuickdrawVersion        = 'qd  ',                        /* quickdraw version */
  670.     gestaltOriginalQD            = 0x000,                        /* original 1-bit QD */
  671.     gestalt8BitQD                = 0x100,                        /* 8-bit color QD */
  672.     gestalt32BitQD                = 0x200,                        /* 32-bit color QD */
  673.     gestalt32BitQD11            = 0x201,                        /* 32-bit color QDv1.1 */
  674.     gestalt32BitQD12            = 0x220,                        /* 32-bit color QDv1.2 */
  675.     gestalt32BitQD13            = 0x230                            /* 32-bit color QDv1.3 */
  676. };
  677.  
  678. enum {
  679.     gestaltQuickdrawFeatures    = 'qdrw',                        /* quickdraw features */
  680.     gestaltHasColor                = 0,                            /* color quickdraw present */
  681.     gestaltHasDeepGWorlds        = 1,                            /* GWorlds can be deeper than 1-bit */
  682.     gestaltHasDirectPixMaps        = 2,                            /* PixMaps can be direct (16 or 32 bit) */
  683.     gestaltHasGrayishTextOr        = 3,                            /* supports text mode grayishTextOr */
  684.     gestaltSupportsMirroring    = 4                                /* Supports video mirroring via the Display Manager. */
  685. };
  686.  
  687. enum {
  688.     gestaltQuickTimeVersion        = 'qtim',                        /* returns version of QuickTime */
  689.     gestaltQuickTime            = 'qtim'
  690. };
  691.  
  692. enum {
  693.     gestaltQuickTimeFeatures    = 'qtrs',
  694.     gestaltPPCQuickTimeLibPresent = 0                            /* PowerPC QuickTime glue library is present */
  695. };
  696.  
  697. enum {
  698.     gestaltPhysicalRAMSize        = 'ram '
  699. };
  700.  
  701. enum {
  702.     gestaltRBVAddr                = 'rbv '
  703. };
  704.  
  705. enum {
  706.     gestaltROMSize                = 'rom '
  707. };
  708.  
  709. enum {
  710.     gestaltROMVersion            = 'romv'
  711. };
  712.  
  713. enum {
  714.     gestaltResourceMgrAttr        = 'rsrc',                        /* Resource Mgr attributes */
  715.     gestaltPartialRsrcs            = 0                                /* True if partial resources exist */
  716. };
  717.  
  718. enum {
  719.     gestaltRealtimeMgrAttr        = 'rtmr',                        /* Realtime manager attributes            */
  720.     gestaltRealtimeMgrPresent    = 0                                /* true if the Realtime manager is present     */
  721. };
  722.  
  723. enum {
  724.     gestaltSCCReadAddr            = 'sccr'
  725. };
  726.  
  727. enum {
  728.     gestaltSCCWriteAddr            = 'sccw'
  729. };
  730.  
  731. enum {
  732.     gestaltScrapMgrAttr            = 'scra',                        /* Scrap Manager attributes */
  733.     gestaltScrapMgrTranslationAware = 0                            /* True if scrap manager is translation aware */
  734. };
  735.  
  736. enum {
  737.     gestaltScriptMgrVersion        = 'scri'
  738. };
  739.  
  740. enum {
  741.     gestaltScriptCount            = 'scr#'
  742. };
  743.  
  744. enum {
  745.     gestaltSCSI                    = 'scsi',                        /* SCSI Manager attributes */
  746.     gestaltAsyncSCSI            = 0,                            /* Supports Asynchronous SCSI */
  747.     gestaltAsyncSCSIINROM        = 1,                            /* Async scsi is in ROM (available for booting) */
  748.     gestaltSCSISlotBoot            = 2                                /* ROM supports Slot-style PRAM for SCSI boots (PDM and later) */
  749. };
  750.  
  751. enum {
  752.     gestaltControlStripAttr        = 'sdev',                        /* Control Strip attributes */
  753.     gestaltControlStripExists    = 0,                            /* Control Strip is installed */
  754.     gestaltControlStripVersionFixed = 1,                        /* Control Strip version Gestalt selector was fixed */
  755.     gestaltControlStripUserFont    = 2,                            /* supports user-selectable font/size */
  756.     gestaltControlStripUserHotKey = 3                            /* support user-selectable hot key to show/hide the window */
  757. };
  758.  
  759. enum {
  760.     gestaltSerialAttr            = 'ser ',                        /* Serial attributes */
  761.     gestaltHasGPIaToDCDa        = 0,                            /* GPIa connected to DCDa*/
  762.     gestaltHasGPIaToRTxCa        = 1,                            /* GPIa connected to RTxCa clock input*/
  763.     gestaltHasGPIbToDCDb        = 2                                /* GPIb connected to DCDb */
  764. };
  765.  
  766. enum {
  767.     gestaltNuBusConnectors        = 'sltc'
  768. };
  769.  
  770. enum {
  771.     gestaltSlotAttr                = 'slot',                        /* slot attributes  */
  772.     gestaltSlotMgrExists        = 0,                            /* true is slot mgr exists  */
  773.     gestaltNuBusPresent            = 1,                            /* NuBus slots are present  */
  774.     gestaltSESlotPresent        = 2,                            /* SE PDS slot present  */
  775.     gestaltSE30SlotPresent        = 3,                            /* SE/30 slot present  */
  776.     gestaltPortableSlotPresent    = 4                                /* Portable’s slot present  */
  777. };
  778.  
  779. enum {
  780.     gestaltFirstSlotNumber        = 'slt1'
  781. };
  782.  
  783. enum {
  784.     gestaltSoundAttr            = 'snd ',                        /* sound attributes */
  785.     gestaltStereoCapability        = 0,                            /* sound hardware has stereo capability */
  786.     gestaltStereoMixing            = 1,                            /* stereo mixing on external speaker */
  787.     gestaltSoundIOMgrPresent    = 3,                            /* The Sound I/O Manager is present */
  788.     gestaltBuiltInSoundInput    = 4,                            /* built-in Sound Input hardware is present */
  789.     gestaltHasSoundInputDevice    = 5,                            /* Sound Input device available */
  790.     gestaltPlayAndRecord        = 6,                            /* built-in hardware can play and record simultaneously */
  791.     gestalt16BitSoundIO            = 7,                            /* sound hardware can play and record 16-bit samples */
  792.     gestaltStereoInput            = 8,                            /* sound hardware can record stereo */
  793.     gestaltLineLevelInput        = 9,                            /* sound input port requires line level */
  794. /* the following bits are not defined prior to Sound Mgr 3.0 */
  795.     gestaltSndPlayDoubleBuffer    = 10,                            /* SndPlayDoubleBuffer available, set by Sound Mgr 3.0 and later */
  796.     gestaltMultiChannels        = 11,                            /* multiple channel support, set by Sound Mgr 3.0 and later */
  797.     gestalt16BitAudioSupport    = 12                            /* 16 bit audio data supported, set by Sound Mgr 3.0 and later */
  798. };
  799.  
  800. enum {
  801.     gestaltStandardFileAttr        = 'stdf',                        /* Standard File attributes */
  802.     gestaltStandardFile58        = 0,                            /* True if selectors 5-8 (StandardPutFile-CustomGetFile) are supported */
  803.     gestaltStandardFileTranslationAware = 1,                    /* True if standard file is translation manager aware */
  804.     gestaltStandardFileHasColorIcons = 2,                        /* True if standard file has 16x16 color icons */
  805.     gestaltStandardFileUseGenericIcons = 3,                        /* Standard file LDEF to use only the system generic icons if true */
  806.     gestaltStandardFileHasDynamicVolumeAllocation = 4            /* True if standard file supports more than 20 volumes */
  807. };
  808.  
  809. enum {
  810.     gestaltSysArchitecture        = 'sysa',                        /* Native System Architecture */
  811.     gestalt68k                    = 1,                            /* Motorola MC68k architecture */
  812.     gestaltPowerPC                = 2                                /* IBM PowerPC architecture */
  813. };
  814.  
  815. enum {
  816.     gestaltSystemVersion        = 'sysv'
  817. };
  818.  
  819. enum {
  820.     gestaltTSMgrVersion            = 'tsmv',                        /* Text Services Mgr version, if present */
  821.     gestaltTSMgr2                = 0x200
  822. };
  823.  
  824. enum {
  825.     gestaltTSMgrAttr            = 'tsma',                        /* Text Services Mgr attributes, if present */
  826.     gestaltTSMDisplayMgrAwareBit = 0,                            /* TSM knows about display manager */
  827.     gestaltTSMdoesTSMTEBit        = 1                                /* TSM has integrated TSMTE */
  828. };
  829.  
  830. enum {
  831.     gestaltTSMTEVersion            = 'tmTV',
  832.     gestaltTSMTE1                = 0x100,
  833.     gestaltTSMTE2                = 0x200
  834. };
  835.  
  836. enum {
  837.     gestaltTSMTEAttr            = 'tmTE',
  838.     gestaltTSMTEPresent            = 0,
  839.     gestaltTSMTE                = 0                                /* gestaltTSMTE is old name for gestaltTSMTEPresent */
  840. };
  841.  
  842. enum {
  843.     gestaltTextEditVersion        = 'te  ',                        /* TextEdit version number */
  844.     gestaltTE1                    = 1,                            /* TextEdit in MacIIci ROM */
  845.     gestaltTE2                    = 2,                            /* TextEdit with 6.0.4 Script Systems on MacIIci (Script bug fixes for MacIIci) */
  846.     gestaltTE3                    = 3,                            /* TextEdit with 6.0.4 Script Systems all but MacIIci */
  847.     gestaltTE4                    = 4,                            /* TextEdit in System 7.0 */
  848.     gestaltTE5                    = 5,                            /* TextWidthHook available in TextEdit */
  849.     gestaltTE6                    = 6                                /* TextEdit in System 8.0 */
  850. };
  851.  
  852. enum {
  853.     gestaltTEAttr                = 'teat',                        /* TextEdit attributes */
  854.     gestaltTEHasGetHiliteRgn    = 0,                            /* TextEdit has TEGetHiliteRgn */
  855.     gestaltTESupportsInlineInput = 1,                            /* TextEdit does Inline Input */
  856.     gestaltTESupportsTextObjects = 2                            /* TextEdit does Text Objects */
  857. };
  858.  
  859. enum {
  860.     gestaltTeleMgrAttr            = 'tele',                        /* Telephone manager attributes */
  861.     gestaltTeleMgrPresent        = 0,
  862.     gestaltTeleMgrPowerPCSupport = 1,
  863.     gestaltTeleMgrSoundStreams    = 2,
  864.     gestaltTeleMgrAutoAnswer    = 3,
  865.     gestaltTeleMgrIndHandset    = 4,
  866.     gestaltTeleMgrSilenceDetect    = 5,
  867.     gestaltTeleMgrNewTELNewSupport = 6
  868. };
  869.  
  870. enum {
  871.     gestaltTermMgrAttr            = 'term',                        /* terminal mgr attributes */
  872.     gestaltTermMgrPresent        = 0,
  873.     gestaltTermMgrErrorString    = 2
  874. };
  875.  
  876. enum {
  877.     gestaltTimeMgrVersion        = 'tmgr',                        /* time mgr version */
  878.     gestaltStandardTimeMgr        = 1,                            /* standard time mgr is present */
  879.     gestaltRevisedTimeMgr        = 2,                            /* revised time mgr is present */
  880.     gestaltExtendedTimeMgr        = 3                                /* extended time mgr is present */
  881. };
  882.  
  883. enum {
  884.     gestaltSpeechAttr            = 'ttsc',                        /* Speech Manager attributes */
  885.     gestaltSpeechMgrPresent        = 0,                            /* bit set indicates that Speech Manager exists */
  886.     gestaltSpeechHasPPCGlue        = 1                                /* bit set indicates that native PPC glue for Speech Manager API exists */
  887. };
  888.  
  889. enum {
  890.     gestaltToolboxTable            = 'tbtt'
  891. };
  892.  
  893. enum {
  894.     gestaltThreadMgrAttr        = 'thds',                        /* Thread Manager attributes */
  895.     gestaltThreadMgrPresent        = 0,                            /* bit true if Thread Mgr is present */
  896.     gestaltSpecificMatchSupport    = 1,                            /* bit true if Thread Mgr supports exact match creation option */
  897.     gestaltThreadsLibraryPresent = 2                            /* bit true if Thread Mgr shared library is present */
  898. };
  899.  
  900. enum {
  901.     gestaltTVAttr                = 'tv  ',                        /* TV version                                        <EX16>     */
  902.     gestaltHasTVTuner            = 0,                            /* supports Philips FL1236F video tuner                <EX16>     */
  903.     gestaltHasSoundFader        = 1,                            /* supports Philips TEA6330 Sound Fader chip        <EX16>     */
  904.     gestaltHasHWClosedCaptioning = 2,                            /* supports Philips SAA5252 Closed Captioning        <EX16>     */
  905.     gestaltHasIRRemote            = 3,                            /* supports CyclopsII Infra Red Remote control        <EX16>     */
  906.     gestaltHasVidDecoderScaler    = 4,                            /* supports Philips SAA7194 Video Decoder/Scaler    <EX16>     */
  907.     gestaltHasStereoDecoder        = 5                                /* supports Sony SBX1637A-01 stereo decoder            <EX16>     */
  908. };
  909.  
  910. enum {
  911.     gestaltVersion                = 'vers',                        /* gestalt version */
  912.     gestaltValueImplementedVers    = 5                                /* version of gestalt where gestaltValue is implemented. */
  913. };
  914.  
  915. enum {
  916.     gestaltVIA1Addr                = 'via1'
  917. };
  918.  
  919. enum {
  920.     gestaltVIA2Addr                = 'via2'
  921. };
  922.  
  923. enum {
  924.     gestaltVMAttr                = 'vm  ',                        /* virtual memory attributes */
  925.     gestaltVMPresent            = 0                                /* true if virtual memory is present */
  926. };
  927.  
  928. enum {
  929.     gestaltTranslationAttr        = 'xlat',                        /* Translation Manager attributes */
  930.     gestaltTranslationMgrExists    = 0,                            /* True if translation manager exists */
  931.     gestaltTranslationMgrHintOrder = 1,                            /* True if hint order reversal in effect */
  932.     gestaltTranslationPPCAvail    = 2,
  933.     gestaltTranslationGetPathAPIAvail = 3
  934. };
  935.  
  936. enum {
  937.     gestaltExtToolboxTable        = 'xttt'
  938. };
  939.  
  940. typedef pascal OSErr (*SelectorFunctionProcPtr)(OSType selector, long *response);
  941.  
  942. #if GENERATINGCFM
  943. typedef UniversalProcPtr SelectorFunctionUPP;
  944. #else
  945. typedef SelectorFunctionProcPtr SelectorFunctionUPP;
  946. #endif
  947.  
  948. enum {
  949.     uppSelectorFunctionProcInfo = kPascalStackBased
  950.          | RESULT_SIZE(SIZE_CODE(sizeof(OSErr)))
  951.          | STACK_ROUTINE_PARAMETER(1, SIZE_CODE(sizeof(OSType)))
  952.          | STACK_ROUTINE_PARAMETER(2, SIZE_CODE(sizeof(long*)))
  953. };
  954.  
  955. #if GENERATINGCFM
  956. #define NewSelectorFunctionProc(userRoutine)        \
  957.         (SelectorFunctionUPP) NewRoutineDescriptor((ProcPtr)(userRoutine), uppSelectorFunctionProcInfo, GetCurrentArchitecture())
  958. #else
  959. #define NewSelectorFunctionProc(userRoutine)        \
  960.         ((SelectorFunctionUPP) (userRoutine))
  961. #endif
  962.  
  963. #if GENERATINGCFM
  964. #define CallSelectorFunctionProc(userRoutine, selector, response)        \
  965.         CallUniversalProc((UniversalProcPtr)(userRoutine), uppSelectorFunctionProcInfo, (selector), (response))
  966. #else
  967. #define CallSelectorFunctionProc(userRoutine, selector, response)        \
  968.         (*(userRoutine))((selector), (response))
  969. #endif
  970.  
  971. #if SystemSevenOrLater
  972.  
  973. #if !GENERATINGCFM
  974. #pragma parameter __D0 Gestalt(__D0, __A1)
  975. #endif
  976. extern pascal OSErr Gestalt(OSType selector, long *response)
  977.  TWOWORDINLINE(0xA1AD, 0x2288);
  978.  
  979. #if !GENERATINGCFM
  980. #pragma parameter __D0 ReplaceGestalt(__D0, __A0, __A1)
  981. #endif
  982. extern pascal OSErr ReplaceGestalt(OSType selector, SelectorFunctionUPP gestaltFunction, SelectorFunctionUPP *oldGestaltFunction)
  983.  FOURWORDINLINE(0x2F09, 0xA5AD, 0x225F, 0x2288);
  984.  
  985. #if !GENERATINGCFM
  986. #pragma parameter __D0 NewGestalt(__D0, __A0)
  987. #endif
  988. extern pascal OSErr NewGestalt(OSType selector, SelectorFunctionUPP gestaltFunction)
  989.  ONEWORDINLINE(0xA3AD);
  990. #else
  991. extern pascal OSErr Gestalt(OSType selector, long *response);
  992. extern pascal OSErr NewGestalt(OSType selector, SelectorFunctionUPP gestaltFunction);
  993. extern pascal OSErr ReplaceGestalt(OSType selector, SelectorFunctionUPP gestaltFunction, SelectorFunctionUPP *oldGestaltFunction);
  994. #endif
  995. #if SystemSevenFiveOrLater
  996. /* These functions are built into System 7.5, but not on earlier systems */
  997. extern pascal OSErr NewGestaltValue(OSType selector, long newValue)
  998.  THREEWORDINLINE(0x303C, 0x0401, 0xABF1);
  999. extern pascal OSErr ReplaceGestaltValue(OSType selector, long replacementValue)
  1000.  THREEWORDINLINE(0x303C, 0x0402, 0xABF1);
  1001. extern pascal OSErr SetGestaltValue(OSType selector, long newValue)
  1002.  THREEWORDINLINE(0x303C, 0x0404, 0xABF1);
  1003. extern pascal OSErr DeleteGestaltValue(OSType selector)
  1004.  THREEWORDINLINE(0x303C, 0x0203, 0xABF1);
  1005. #else
  1006. #endif
  1007.  
  1008. #if PRAGMA_IMPORT_SUPPORTED
  1009. #pragma import off
  1010. #endif
  1011.  
  1012. #if PRAGMA_ALIGN_SUPPORTED
  1013. #pragma options align=reset
  1014. #endif
  1015.  
  1016. #ifdef __cplusplus
  1017. }
  1018. #endif
  1019.  
  1020. #endif /* __GESTALT__ */
  1021.